package com.heima.admin.v1.controller;

import com.heima.common.dtos.PageResult;
import com.heima.common.dtos.ResponseResult;
import com.heima.feign.WemediaFeign;
import com.heima.model.media.dtos.WmNewsPageDto;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
public class AdminReviewController {

@Autowired
private WemediaFeign feign;

    @PostMapping("/api/v1/news_auth/list")
    public PageResult newsAuth(@RequestBody WmNewsPageDto dto){
    return feign.newsAuth(dto);
    }
    @GetMapping("/api/v1/news_auth/one/{id}")
    public ResponseResult one(@PathVariable("id")Integer id){
        return feign.one(id);
    }
}
